/*
 * @Author: zhumeng@sensorsdata.cn
 * @Date: 2024-04-02 19:55:40
 * @LastEditTime: 2024-04-03 20:32:54
 * @Description:
 */

import { Spacer, Input } from '@nextui-org/react'
import { HomeNavbar, MoneyCard, Recorder, Table } from '../components'
import db from '../db/data.js'

const Home = () => {
  return (
    <div>
      <HomeNavbar>
        <Recorder />
      </HomeNavbar>

      <div className="grid gap-1 grid-cols-4">
        <Table
          rows={db.data}
          columns={[
            { label: '账户', key: 'account_name' },
            { label: '金额', key: 'amount' }
          ]}
        />

        {/* <div className="flex"></div> */}
        {/* <Spacer x={4} /> */}
        {[
          {
            type: 'alipay'
          },
          {
            type: 'wechat'
          }
        ].map((info) => {
          const { type } = info
          return (
            <>
              <MoneyCard key={type} type={type} />
            </>
          )
        })}
      </div>
      <div className="col-span-2"></div>
    </div>
  )
}
export default Home
